<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script type="text/javascript" src="jstool/jquery-3.1.1.min.js"></script>
    <script type="text/javascript" src="jstool/bootstrap-3.3.7/js/bootstrap.js"></script>
    <link rel="stylesheet" type="text/css" href="jstool/bootstrap-3.3.7/css/bootstrap.css" />
    <link rel="stylesheet" type="text/css" href="jstool/bootstrap-3.3.7/css/bootstrap-theme.css" />
    <script type="text/javascript">
        $(function(){
//            var base = 'http://www.51d1d.com/chezhujie';

//            var base = 'http://localhost:8080/vote';
          /*  $("a").each(function(){
                $(this).attr('href',$(this).attr('href').replace('${base}',base));
            });*/
//            alert($('a').attr('href').replace('${base}',base));
//            $('a').attr('href',$('a').attr('href').replace('${base}',base));
            (function ($) {
                $.getUrlParam = function (name) {
                    var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)");
                    var r = window.location.search.substr(1).match(reg);
                    if (r != null) return unescape(r[2]); return null;
                }
            })(jQuery);

            //方法二：
            var xx = $.getUrlParam('code');
            $('.getFocusId').each(function(){
                $(this).attr('href', $(this).attr('href')+xx);
            });

            $('#nl').text(xx);
        });


    </script>
</head>
<body>

<h1><a href="wxhtml/tunedupPay.html?code=">测试微信支付</a></h1>
<h1><a href="yyy.html?code=">重置</a></h1>
<h1>code:<span id="nl"></span></h1>
<!--<h1><a href="wxhtml/myInfo.html?code=">myInfo.html</a></h1>-->

    <!--<h1><a href="wxhtml/otherInfo.html?code=">otherInfo.html</a></h1>-->
    <h1>测试机上运行</h1>
    <h1><a href="https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx5e3453d525417756&redirect_uri=http%3a%2f%2fwww.51d1d.com%2fchezhujie%2fyyy.html&response_type=code&scope=snsapi_userinfo&state=#wechat_redirect">喜乐回家获取code</a></h1>
    <h1><a href="https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx73af8dec75fd96bd&redirect_uri=http%3a%2f%2fwww.51d1d.com%2fchezhujie%2fyyy.html&response_type=code&scope=snsapi_userinfo&state=#wechat_redirect">正式获取code</a></h1>
    <h1><a href="jie%2fyyhttps://open.weixin.qq.com/connect/oauth2/authorize?appid=wx73af8dec75fd96bd&redirect_uri=http%3a%2f%2fu1641778.jisuwebapp.com%2findex.php&response_type=code&scope=snsapi_userinfo&state=#wechat_redirect">哈路出行获取code</a></h1>
    <!--<h1>正式机上运行</h1>-->
    <!--<h1><a href="https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx5e3453d525417756&redirect_uri=http%3a%2f%2f2017czj.televehicle.com%2fchezhujie%2findex.html&response_type=code&scope=snsapi_userinfo&state=#wechat_redirect">测试获取code</a></h1>-->
    <!--<h1><a href="https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx73af8dec75fd96bd&redirect_uri=http%3a%2f%2f2017czj.televehicle.com%2fchezhujie%2findex.html&response_type=code&scope=snsapi_userinfo&state=#wechat_redirect">正式获取code</a></h1>-->

    <!--<h1><a  class="getFocusId" href="weixin/getWeixinInfoGzh.do?code=">获取用户是否关注微信公众号</a></h1>-->
    <!--<h1><a class="getFocusId" href="recommendpic/getRecommendpic.do?code=">测试是否弹窗</a></h1>-->
</body>
</html>